package com.example.mybatisx.controller;


import com.example.mybatisx.service.SysUserService;
import com.example.mybatisx.service.SysUserSlaveService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class SysUserController {

    @Autowired
    private SysUserService sysUserService;

    @Autowired
    private SysUserSlaveService sysUserSlaveService;


    @RequestMapping("getMasterUser")
    public Object getMasterUser(){
        return sysUserService.getMasterUser();
    }


    @RequestMapping("getSlaveUser")
    public Object getSlaveUser(){
        return sysUserSlaveService.getSlaveUser();
    }

    @RequestMapping("addMasterUser")
    public Object addMasterUser(){
        return sysUserService.addMasterUser();
    }
    @RequestMapping("addSlaveUser")
    public Object addSlaveUser(){
        return sysUserSlaveService.addSlaveUser();
    }

}
